package com.zsrt.publish;

import javax.xml.ws.Endpoint;

import com.zsrt.service.CalService;
import com.zsrt.service.impl.CalServiceImpl;

/**
 * 发布webservice
 * @author scott
 *
 */
public class CalPublish {
	
	public static void main(String[] args) {
		
		//客户端访问的地址  http://127.0.0.1:8899/cal/add?wsdl
		String url ="http://127.0.0.1:8899/cal/add";
		
		//真正干活的人
		CalService  cal = new CalServiceImpl();
		
		//发布webservice
		Endpoint.publish(url, cal);
		
		
		
		System.out.println("发布服务成功...");
		
		System.out.println(url+"?wsdl");
		
		
	}

}
